import { axios } from '@/utils/request'

const api = {
  get_info: '/alipay-third-app/get-info',
  get_params: '/alipay-third-app/get-params',
  get_status: '/alipay-third-app/get-status',
  get_app_pay: '/alipay-third-app/get-app-pay'
}

export default api

export function getInfo (parameter) {
  return axios({
    url: api.get_info,
    method: 'get',
    params: parameter
  })
}

export function getParams (parameter) {
  return axios({
    url: api.get_params,
    method: 'get',
    params: parameter
  })
}

export function getStatus (parameter) {
  return axios({
    url: api.get_status,
    method: 'get',
    params: parameter
  })
}

export function getAppPay (parameter) {
  return axios({
    url: api.get_app_pay,
    method: 'post',
    data: parameter
  })
}